# -*- coding: utf-8 -*-
<%inherit file="/admin.mako"/>
<p style="text-align: center"><span class="destak">Mostras</span></p>
${h.form(h.url(action='save',id=c.form_result['cdmostra']),method='post')}
${h.hidden_field('cdmostra',value=c.form_result['cdmostra'] or '')}
<div id="list" class="inner_context">
  <table class="tablelist" width="100%" cellpadding="0" cellmargin="0">    
    <tbody class="ligth_gray">
      <tr>
        <td align="right" width="15%"><strong>Nome</strong></td>
        <td width="*">${h.text_field('nmmostra',class_='ed',size='50',maxlength='100',value=c.form_result['nmmostra'] or '')}</td>
      </tr>
    </tbody>
  </table>
<br/>
${h.submit(value=' Salvar ',class_='ed')} <input type="button" name="btreset" id="btreset" value=" Limpar " class="ed"/>
</div>
${h.end_form()}
<br/>
<div id="list" class="inner_context">
  <table class="tablelist" width="100%" cellpadding="0" cellmargin="0">    
    <thead>
      <tr>
        <th width="90%" align="left">Mostras cadastradas</th>
        <th width="*">&nbsp;</th>
      </tr>
    </thead>
    <tbody class="ligth_gray">
%if c.list:
    %for mostra in c.list:
        <tr>
          <td><a href="${h.url_for(action='edit',id=mostra.cdmostra)}">${mostra.nmmostra}</a></td>
          <td><span class="destak">[</span><a href="${h.url_for(action='delete',id=mostra.cdmostra)}">X</a><span class="destak">]</span></td>
        </tr>
    %endfor
%endif
    </tbody>
  </table>
</div>
